<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      div {
        width: 200px;
        height: 25px;
        border: 1px solid black;
        margin: 0px auto;
        position: relative;
      }
      div::after {
        content: "";
        position: absolute;
        top: 7px;
        right: 10px;
        width: 5px;
        height: 5px;
        border-right: 1px solid black;
        border-bottom: 1px solid black;
        transform: rotate(45deg);
        transition: all 1s;
      }
      div:hover::after {
        transform: rotate(225deg);
        transform-origin: right bottom;
      }
    </style>
  </head>
  <body>
    <div></div>
  </body>
</html>
